 /* Copyright 2018 JDCLOUD.COM

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http:#www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.





Contact: 

NOTE: This class is auto generated by the jdcloud code generator program.
*/


#import <Foundation/Foundation.h>
#import <JDCloudOCSDKPortal/PortalModel.h>

@implementation LinkVo
-(id) initWithId:(NSNumber*) idValue
      name:(NSString*)name
      linkUrl:(NSString*)linkUrl
      clstag:(NSString*)clstag
      sort:(NSNumber*)sort
      operatorValue:(NSString*)operatorValue
      status:(NSString*)status
      createTime:(NSString*)createTime
      modifyTime:(NSString*)modifyTime { 
     self.idValue = idValue;               
     self.name = name;               
     self.linkUrl = linkUrl;               
     self.clstag = clstag;               
     self.sort = sort;               
     self.operatorValue = operatorValue;               
     self.status = status;               
     self.createTime = createTime;               
     self.modifyTime = modifyTime;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self idValue])
    {
        [result setValue:[self idValue] forKey:@"id"];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self linkUrl])
    {
        [result setValue:[self linkUrl] forKey:@"linkUrl"];
    }
    if([self clstag])
    {
        [result setValue:[self clstag] forKey:@"clstag"];
    }
    if([self sort])
    {
        [result setValue:[self sort] forKey:@"sort"];
    }
    if([self operatorValue])
    {
        [result setValue:[self operatorValue] forKey:@"operator"];
    }
    if([self status])
    {
        [result setValue:[self status] forKey:@"status"];
    }
    if([self createTime])
    {
        [result setValue:[self createTime] forKey:@"createTime"];
    }
    if([self modifyTime])
    {
        [result setValue:[self modifyTime] forKey:@"modifyTime"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.idValue = [dictionary objectForKey:@"id"];
    self.name = [dictionary objectForKey:@"name"];
    self.linkUrl = [dictionary objectForKey:@"linkUrl"];
    self.clstag = [dictionary objectForKey:@"clstag"];
    self.sort = [dictionary objectForKey:@"sort"];
    self.operatorValue = [dictionary objectForKey:@"operator"];
    self.status = [dictionary objectForKey:@"status"];
    self.createTime = [dictionary objectForKey:@"createTime"];
    self.modifyTime = [dictionary objectForKey:@"modifyTime"];
    return self;
}
 @end
@implementation NoticeVo
-(id) initWithUuid:(NSNumber*) uuid
      idValue:(NSNumber*)idValue
      title:(NSString*)title
      type:(NSString*)type
      goTop:(NSString*)goTop
      inlet:(NSString*)inlet
      createTime:(NSString*)createTime
      updateTime:(NSString*)updateTime
      createPin:(NSString*)createPin
      yn:(NSString*)yn
      content:(NSString*)content
      startTime:(NSString*)startTime
      endTime:(NSString*)endTime
      site:(NSNumber*)site
      pageNum:(NSNumber*)pageNum
      pageSize:(NSNumber*)pageSize
      lang:(NSString*)lang
      langId:(NSNumber*)langId
      ts:(NSString*)ts { 
     self.uuid = uuid;               
     self.idValue = idValue;               
     self.title = title;               
     self.type = type;               
     self.goTop = goTop;               
     self.inlet = inlet;               
     self.createTime = createTime;               
     self.updateTime = updateTime;               
     self.createPin = createPin;               
     self.yn = yn;               
     self.content = content;               
     self.startTime = startTime;               
     self.endTime = endTime;               
     self.site = site;               
     self.pageNum = pageNum;               
     self.pageSize = pageSize;               
     self.lang = lang;               
     self.langId = langId;               
     self.ts = ts;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self uuid])
    {
        [result setValue:[self uuid] forKey:@"uuid"];
    }
    if([self idValue])
    {
        [result setValue:[self idValue] forKey:@"id"];
    }
    if([self title])
    {
        [result setValue:[self title] forKey:@"title"];
    }
    if([self type])
    {
        [result setValue:[self type] forKey:@"type"];
    }
    if([self goTop])
    {
        [result setValue:[self goTop] forKey:@"goTop"];
    }
    if([self inlet])
    {
        [result setValue:[self inlet] forKey:@"inlet"];
    }
    if([self createTime])
    {
        [result setValue:[self createTime] forKey:@"createTime"];
    }
    if([self updateTime])
    {
        [result setValue:[self updateTime] forKey:@"updateTime"];
    }
    if([self createPin])
    {
        [result setValue:[self createPin] forKey:@"createPin"];
    }
    if([self yn])
    {
        [result setValue:[self yn] forKey:@"yn"];
    }
    if([self content])
    {
        [result setValue:[self content] forKey:@"content"];
    }
    if([self startTime])
    {
        [result setValue:[self startTime] forKey:@"startTime"];
    }
    if([self endTime])
    {
        [result setValue:[self endTime] forKey:@"endTime"];
    }
    if([self site])
    {
        [result setValue:[self site] forKey:@"site"];
    }
    if([self pageNum])
    {
        [result setValue:[self pageNum] forKey:@"pageNum"];
    }
    if([self pageSize])
    {
        [result setValue:[self pageSize] forKey:@"pageSize"];
    }
    if([self lang])
    {
        [result setValue:[self lang] forKey:@"lang"];
    }
    if([self langId])
    {
        [result setValue:[self langId] forKey:@"langId"];
    }
    if([self ts])
    {
        [result setValue:[self ts] forKey:@"ts"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.uuid = [dictionary objectForKey:@"uuid"];
    self.idValue = [dictionary objectForKey:@"id"];
    self.title = [dictionary objectForKey:@"title"];
    self.type = [dictionary objectForKey:@"type"];
    self.goTop = [dictionary objectForKey:@"goTop"];
    self.inlet = [dictionary objectForKey:@"inlet"];
    self.createTime = [dictionary objectForKey:@"createTime"];
    self.updateTime = [dictionary objectForKey:@"updateTime"];
    self.createPin = [dictionary objectForKey:@"createPin"];
    self.yn = [dictionary objectForKey:@"yn"];
    self.content = [dictionary objectForKey:@"content"];
    self.startTime = [dictionary objectForKey:@"startTime"];
    self.endTime = [dictionary objectForKey:@"endTime"];
    self.site = [dictionary objectForKey:@"site"];
    self.pageNum = [dictionary objectForKey:@"pageNum"];
    self.pageSize = [dictionary objectForKey:@"pageSize"];
    self.lang = [dictionary objectForKey:@"lang"];
    self.langId = [dictionary objectForKey:@"langId"];
    self.ts = [dictionary objectForKey:@"ts"];
    return self;
}
 @end
@implementation ProductTxt
-(id) initWithId:(NSNumber*) idValue
      productId:(NSNumber*)productId
      templet:(NSString*)templet
      txt:(NSString*)txt
      sort:(NSNumber*)sort
      createTime:(NSString*)createTime
      updateTime:(NSString*)updateTime
      lang:(NSString*)lang { 
     self.idValue = idValue;               
     self.productId = productId;               
     self.templet = templet;               
     self.txt = txt;               
     self.sort = sort;               
     self.createTime = createTime;               
     self.updateTime = updateTime;               
     self.lang = lang;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self idValue])
    {
        [result setValue:[self idValue] forKey:@"id"];
    }
    if([self productId])
    {
        [result setValue:[self productId] forKey:@"productId"];
    }
    if([self templet])
    {
        [result setValue:[self templet] forKey:@"templet"];
    }
    if([self txt])
    {
        [result setValue:[self txt] forKey:@"txt"];
    }
    if([self sort])
    {
        [result setValue:[self sort] forKey:@"sort"];
    }
    if([self createTime])
    {
        [result setValue:[self createTime] forKey:@"createTime"];
    }
    if([self updateTime])
    {
        [result setValue:[self updateTime] forKey:@"updateTime"];
    }
    if([self lang])
    {
        [result setValue:[self lang] forKey:@"lang"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.idValue = [dictionary objectForKey:@"id"];
    self.productId = [dictionary objectForKey:@"productId"];
    self.templet = [dictionary objectForKey:@"templet"];
    self.txt = [dictionary objectForKey:@"txt"];
    self.sort = [dictionary objectForKey:@"sort"];
    self.createTime = [dictionary objectForKey:@"createTime"];
    self.updateTime = [dictionary objectForKey:@"updateTime"];
    self.lang = [dictionary objectForKey:@"lang"];
    return self;
}
 @end
@implementation Navigation
-(id) initWithId:(NSNumber*) idValue
      name:(NSString*)name
      descriptionValue:(NSString*)descriptionValue
      iconUrl:(NSString*)iconUrl
      iconClass:(NSString*)iconClass
      webUrl:(NSString*)webUrl
      url:(NSString*)url
      productStatus:(NSNumber*)productStatus
      sort:(NSNumber*)sort
      createTime:(NSString*)createTime
      parentId:(NSNumber*)parentId
      updateTime:(NSString*)updateTime
      level:(NSNumber*)level
      label:(NSString*)label
      helpUrl:(NSString*)helpUrl
      selfRun:(NSString*)selfRun
      lang:(NSString*)lang
      extChildren:(NSArray<Navigation*>*)extChildren { 
     self.idValue = idValue;               
     self.name = name;               
     self.descriptionValue = descriptionValue;               
     self.iconUrl = iconUrl;               
     self.iconClass = iconClass;               
     self.webUrl = webUrl;               
     self.url = url;               
     self.productStatus = productStatus;               
     self.sort = sort;               
     self.createTime = createTime;               
     self.parentId = parentId;               
     self.updateTime = updateTime;               
     self.level = level;               
     self.label = label;               
     self.helpUrl = helpUrl;               
     self.selfRun = selfRun;               
     self.lang = lang;               
     self.extChildren = extChildren;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self idValue])
    {
        [result setValue:[self idValue] forKey:@"id"];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self descriptionValue])
    {
        [result setValue:[self descriptionValue] forKey:@"description"];
    }
    if([self iconUrl])
    {
        [result setValue:[self iconUrl] forKey:@"iconUrl"];
    }
    if([self iconClass])
    {
        [result setValue:[self iconClass] forKey:@"iconClass"];
    }
    if([self webUrl])
    {
        [result setValue:[self webUrl] forKey:@"webUrl"];
    }
    if([self url])
    {
        [result setValue:[self url] forKey:@"url"];
    }
    if([self productStatus])
    {
        [result setValue:[self productStatus] forKey:@"productStatus"];
    }
    if([self sort])
    {
        [result setValue:[self sort] forKey:@"sort"];
    }
    if([self createTime])
    {
        [result setValue:[self createTime] forKey:@"createTime"];
    }
    if([self parentId])
    {
        [result setValue:[self parentId] forKey:@"parentId"];
    }
    if([self updateTime])
    {
        [result setValue:[self updateTime] forKey:@"updateTime"];
    }
    if([self level])
    {
        [result setValue:[self level] forKey:@"level"];
    }
    if([self label])
    {
        [result setValue:[self label] forKey:@"label"];
    }
    if([self helpUrl])
    {
        [result setValue:[self helpUrl] forKey:@"helpUrl"];
    }
    if([self selfRun])
    {
        [result setValue:[self selfRun] forKey:@"selfRun"];
    }
    if([self lang])
    {
        [result setValue:[self lang] forKey:@"lang"];
    }
    if([self extChildren])
    {
        NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
        for (int i =0 ; i< [[self extChildren] count]; i++) {
            Navigation* item = [[self extChildren] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"extChildren"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.idValue = [dictionary objectForKey:@"id"];
    self.name = [dictionary objectForKey:@"name"];
    self.descriptionValue = [dictionary objectForKey:@"description"];
    self.iconUrl = [dictionary objectForKey:@"iconUrl"];
    self.iconClass = [dictionary objectForKey:@"iconClass"];
    self.webUrl = [dictionary objectForKey:@"webUrl"];
    self.url = [dictionary objectForKey:@"url"];
    self.productStatus = [dictionary objectForKey:@"productStatus"];
    self.sort = [dictionary objectForKey:@"sort"];
    self.createTime = [dictionary objectForKey:@"createTime"];
    self.parentId = [dictionary objectForKey:@"parentId"];
    self.updateTime = [dictionary objectForKey:@"updateTime"];
    self.level = [dictionary objectForKey:@"level"];
    self.label = [dictionary objectForKey:@"label"];
    self.helpUrl = [dictionary objectForKey:@"helpUrl"];
    self.selfRun = [dictionary objectForKey:@"selfRun"];
    self.lang = [dictionary objectForKey:@"lang"];
    NSArray* extChildrenArray = [dictionary objectForKey:@"extChildren"];
    if(extChildrenArray&&![extChildrenArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [extChildrenArray count];i++)
        {
            Navigation* item = [[Navigation alloc]initWithDic:[extChildrenArray objectAtIndex:i]];
            if(item)
            {
                [propertyArray addObject:item];
            }
        }
        self.extChildren = propertyArray;
    }
    return self;
}
 @end
@implementation Product
-(id) initWithId:(NSNumber*) idValue
      name:(NSString*)name
      url:(NSString*)url
      parentNavigationId:(NSNumber*)parentNavigationId
      navigationId:(NSNumber*)navigationId
      createTime:(NSString*)createTime
      updateTime:(NSString*)updateTime
      lang:(NSString*)lang
      txtVoList:(NSArray<ProductTxt*>*)txtVoList { 
     self.idValue = idValue;               
     self.name = name;               
     self.url = url;               
     self.parentNavigationId = parentNavigationId;               
     self.navigationId = navigationId;               
     self.createTime = createTime;               
     self.updateTime = updateTime;               
     self.lang = lang;               
     self.txtVoList = txtVoList;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self idValue])
    {
        [result setValue:[self idValue] forKey:@"id"];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self url])
    {
        [result setValue:[self url] forKey:@"url"];
    }
    if([self parentNavigationId])
    {
        [result setValue:[self parentNavigationId] forKey:@"parentNavigationId"];
    }
    if([self navigationId])
    {
        [result setValue:[self navigationId] forKey:@"navigationId"];
    }
    if([self createTime])
    {
        [result setValue:[self createTime] forKey:@"createTime"];
    }
    if([self updateTime])
    {
        [result setValue:[self updateTime] forKey:@"updateTime"];
    }
    if([self lang])
    {
        [result setValue:[self lang] forKey:@"lang"];
    }
    if([self txtVoList])
    {
        NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
        for (int i =0 ; i< [[self txtVoList] count]; i++) {
            ProductTxt* item = [[self txtVoList] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"txtVoList"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.idValue = [dictionary objectForKey:@"id"];
    self.name = [dictionary objectForKey:@"name"];
    self.url = [dictionary objectForKey:@"url"];
    self.parentNavigationId = [dictionary objectForKey:@"parentNavigationId"];
    self.navigationId = [dictionary objectForKey:@"navigationId"];
    self.createTime = [dictionary objectForKey:@"createTime"];
    self.updateTime = [dictionary objectForKey:@"updateTime"];
    self.lang = [dictionary objectForKey:@"lang"];
    NSArray* txtVoListArray = [dictionary objectForKey:@"txtVoList"];
    if(txtVoListArray&&![txtVoListArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [txtVoListArray count];i++)
        {
            ProductTxt* item = [[ProductTxt alloc]initWithDic:[txtVoListArray objectAtIndex:i]];
            if(item)
            {
                [propertyArray addObject:item];
            }
        }
        self.txtVoList = propertyArray;
    }
    return self;
}
 @end
 
 


